def singleton(cls,*args,**kw):
    instances = {}
    def _singleton():
        if cls not in instances:
            instances[cls] = cls(*args, **kw)
        return instances[cls]
    return _singleton


class GameRoomFullException(Exception):
    def __init__(self):
        print "Room full"
        
class GameRoomPosFullException(Exception):
    def __init__(self):
        print "RoomPos full"